<div class="row justify-content-center">
    <div class="col-8">
        <form name="editForm" role="form" novalidate (ngSubmit)="save()" #editForm="ngForm">
            <h2 id="jhi-hdfs-log-heading" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.home.createOrEditLabel">Create or edit a Hdfs Log</h2>
            <div>
                <jhi-alert-error></jhi-alert-error>
                <div class="form-group" [hidden]="!hdfsLog.id">
                    <label for="id" jhiTranslate="global.field.id">ID</label>
                    <input type="text" class="form-control" id="id" name="id"
                        [(ngModel)]="hdfsLog.id" readonly />
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.name" for="field_name" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.name' | translate">Name</label>
                    <input type="text" class="form-control" name="name" id="field_name"
                        [(ngModel)]="hdfsLog.name" maxlength="20"/>
                    <div [hidden]="!(editForm.controls.name?.dirty && editForm.controls.name?.invalid)">
                        <small class="form-text text-danger"
                        [hidden]="!editForm.controls.name?.errors?.maxlength" jhiTranslate="entity.validation.maxlength" translateValues="{ max: 20 }">
                        This field cannot be longer than 20 characters.
                        </small>
                    </div>
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.src" for="field_src" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.src' | translate">Src</label>
                    <input type="text" class="form-control" name="src" id="field_src"
                        [(ngModel)]="hdfsLog.src" maxlength="512"/>
                    <div [hidden]="!(editForm.controls.src?.dirty && editForm.controls.src?.invalid)">
                        <small class="form-text text-danger"
                        [hidden]="!editForm.controls.src?.errors?.maxlength" jhiTranslate="entity.validation.maxlength" translateValues="{ max: 512 }">
                        This field cannot be longer than 512 characters.
                        </small>
                    </div>
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.dst" for="field_dst" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.dst' | translate">Dst</label>
                    <input type="text" class="form-control" name="dst" id="field_dst"
                        [(ngModel)]="hdfsLog.dst" maxlength="512"/>
                    <div [hidden]="!(editForm.controls.dst?.dirty && editForm.controls.dst?.invalid)">
                        <small class="form-text text-danger"
                        [hidden]="!editForm.controls.dst?.errors?.maxlength" jhiTranslate="entity.validation.maxlength" translateValues="{ max: 512 }">
                        This field cannot be longer than 512 characters.
                        </small>
                    </div>
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.totalSize" for="field_totalSize" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.totalSize' | translate">Total Size</label>
                    <input type="number" class="form-control" name="totalSize" id="field_totalSize"
                        [(ngModel)]="hdfsLog.totalSize" />
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.currentSize" for="field_currentSize" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.currentSize' | translate">Current Size</label>
                    <input type="number" class="form-control" name="currentSize" id="field_currentSize"
                        [(ngModel)]="hdfsLog.currentSize" />
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.process" for="field_process" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.process' | translate">Process</label>
                    <input type="number" class="form-control" name="process" id="field_process"
                        [(ngModel)]="hdfsLog.process" />
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.state" for="field_state" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.state' | translate">State</label>
                    <input type="number" class="form-control" name="state" id="field_state"
                        [(ngModel)]="hdfsLog.state" />
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.desc" for="field_desc" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.desc' | translate">Desc</label>
                    <input type="text" class="form-control" name="desc" id="field_desc"
                        [(ngModel)]="hdfsLog.desc" maxlength="512"/>
                    <div [hidden]="!(editForm.controls.desc?.dirty && editForm.controls.desc?.invalid)">
                        <small class="form-text text-danger"
                        [hidden]="!editForm.controls.desc?.errors?.maxlength" jhiTranslate="entity.validation.maxlength" translateValues="{ max: 512 }">
                        This field cannot be longer than 512 characters.
                        </small>
                    </div>
                </div>
                <div class="form-group">
                    <label class="form-control-label" jhiTranslate="hdfsutilApp.hdfsutilHdfsLog.createdDate" for="field_createdDate" [ngbTooltip]="'hdfsutilApp.hdfsutilHdfsLog.help.createdDate' | translate">Created Date</label>
                    <div class="d-flex">
                        <input id="field_createdDate" type="datetime-local" class="form-control" name="createdDate" [(ngModel)]="createdDate"
                        />
                    </div>
                </div>

            </div>
            <div>
                <button type="button" id="cancel-save" class="btn btn-secondary"  (click)="previousState()">
                    <fa-icon [icon]="'ban'"></fa-icon>&nbsp;<span jhiTranslate="entity.action.cancel">Cancel</span>
                </button>
                <button type="submit" id="save-entity" [disabled]="editForm.form.invalid || isSaving" class="btn btn-primary">
                    <fa-icon [icon]="'save'"></fa-icon>&nbsp;<span jhiTranslate="entity.action.save">Save</span>
                </button>
            </div>
        </form>
    </div>
</div>
